package com.jackrain.nea.web.model;

import com.alibaba.fastjson.JSONObject;
import com.jackrain.nea.core.model.domain.AdColumn;
import org.apache.commons.lang3.builder.EqualsBuilder;

import java.io.Serializable;

public class MenuObject implements Serializable{

    private static final long serialVersionUID = -1;

    private int id;

    private String type;

    private String value;

    private String label;

    private String url;

    private JSONObject webaction;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public String getLabel() {
        return label;
    }

    public void setLabel(String label) {
        this.label = label;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public JSONObject getWebaction() {
        return webaction;
    }

    public void setWebaction(JSONObject webaction) {
        this.webaction = webaction;
    }

    @Override
    public boolean equals(Object o) {
        if (o == null) {
            return false;
        }
        if (o == this) {
            return true;
        }
        if (o.getClass() != getClass()) {
            return false;
        }
        MenuObject e = (MenuObject) o;
        return new EqualsBuilder().
                append(getType(), e.getType()).
                append(getId(), e.getId()).
                isEquals();
    }

}
